<{extends file='layout_uc.html'}>
<{block name='body'}>
<div class="uc_title m_10">
		<label><span>预购席位</span></label>
	</div>

	<div class="prompt m_10">
		<p><b class="orange f14">提示：</b>您有 <strong style="color:#F60;"><{$num}></strong> 个预购席位。<a href="?m=AC_Relation_Manage">[席位管理]</a></p>
	</div>

	<div class="node">
		<div class="form_content">
                    <{if $check_pwd}>
			<form action='#' method='post'>
				<table class="form_table mt_10" width="100%" cellpadding="0" cellspacing="0">
					<tr><th>预购数量：</th><td><select name="SeatNumber" id="tbSeatNumber"><option value="0">请选择</option><option value="10">10</option><option value="20">20</option><option value="30">30</option></select><label><span class='red'>*</span> 请选择席位数量</label>
						</td></tr>
					<tr><th>小计金额：</th><td><strong id="sum" style="font-size:14px; font-weight:bold;">0.00</strong> 元</td></tr>
					<tr><th>账户余额：</th><td><{$blance}></td></tr>
					<tr><th>提成金额：</th><td><strong id="tichen" style="color:#090; font-size:14px; font-weight:bold;">0.00</strong> 元</td></tr>
					<tr><th>应付金额：</th><td><strong id="yingfu" style="color:#F00; font-size:14px; font-weight:bold;">0.00</strong> 元</td></tr>
					<tr><th></th><td><label class="btn"><input type="submit" value="订购" onclick="return confirm('您确定要订购'+$('#tbSeatNumber').val()+'个席位吗？此操作不可撤回！');" /></label><label class="btn"><input type="reset" value="取消" /></label></td></tr>
				</table><input type="hidden" name="action" value="save" />                                
    
			</form>
                    <{else}>
                    <form method="post" action="#">
                        <div class="masker">
                            <p class="em">为了您的账户安全，请您输入二级密码后继续操作</p><p><input type="password" name="Password" class="normal" TextMode="Password" /><br /><label class="btn"><input type="submit" value="确定" /></label></p>
                        </div>
                        <input type="hidden" name="action" value="checkpwd" />
                    </form>
                    <{/if}>
		</div>

	</div>

<script type="text/javascript">
    jQuery(document).ready(function ($) {
        $('#tbSeatNumber').change(function () {
            if(!$(this).val()) return;
            var n = $(this).val()*1;
            $('#sum').text(n * 300);
            var yj = 8;
            switch (n) {
                case 20:
                    yj = 12;
                    break;
                case 30:
                    yj = 16;
                    break;
            }
            $('#tichen').text(n * yj);
            $('#yingfu').text(n * (300 - yj));
        });
    });
</script>
<{/block}>